package com.rockcent.mall.lib.dto;

import com.rockcent.common.domain.DtoEntity;
import com.rockcent.mall.lib.domain.UserAdmin;
import com.rockcent.mall.lib.domain.UserMall;
import com.rockcent.mall.lib.domain.UserMerchant;
import com.rockcent.mall.lib.domain.enumclass.SystemType;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * Created by oyhk on 16/7/13.
 *
 */
public class UserInfoDto extends DtoEntity {

    // 用户名
    public String username;
    // 密码
    public String password;
    // 当前登录平台
    public MallDto mall;
    // 当前登录商家
    public MerchantDto merchant;
    // 平台 map
    public Map<String, MallDto> mallMap;
    // 商家 map
    public Map<String, MerchantDto> merchantMap;
    // 权限 map
    public Map<String, List<MallMerchantDto>> permissionMap;
    // 返回url
    public String backUrl;
    // 验证码
    public String captcha;
    // 权限列表
    public List<Map<String, Object>> permissionList;
    // 登录后的userToken
    public String userToken;
    // 登录域名
    public String loginDomain;
    // 需要设置cookie的自定义域名列表
    public List<String> setCookieCustomerDomainList;
    //登录来源地址
    public String referer;
    //是否是自定义登录
    public String customLogin;
    //平台链接
    public String customLoginMallUrl;
    //商家链接
    public String customLoginMerchantUrl;
    //手机
    private String mobile;
    //邮箱
    private String email;
    // R端用户
    private UserAdmin userAdmin;
    // 系统类型
    private String systemType;
    //错误信息
    private List<String> errorMessage;
    //是否超级管理员 YES:是 NO:否
    private String isSuper;
    //拥有的资源
    private List<MenuTreeDTO> resourceList;
    //域名链接
    private String hostname;
    private UserMall userMall;
    private UserMerchant userMerchant;


    public MallDto getMall() {
        return mall;
    }

    public void setMall(MallDto mall) {
        this.mall = mall;
    }

    public MerchantDto getMerchant() {
        return merchant;
    }

    public String getUserToken() {
        return userToken;
    }

    public void setUserToken(String userToken) {
        this.userToken = userToken;
    }

    public void setMerchant(MerchantDto merchant) {
        this.merchant = merchant;
    }


    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public Map<String, MallDto> getMallMap() {
        return mallMap;
    }

    public void setMallMap(Map<String, MallDto> mallMap) {
        this.mallMap = mallMap;
    }

    public Map<String, MerchantDto> getMerchantMap() {
        return merchantMap;
    }

    public void setMerchantMap(Map<String, MerchantDto> merchantMap) {
        this.merchantMap = merchantMap;
    }

    public String getBackUrl() {
        return backUrl;
    }

    public void setBackUrl(String backUrl) {
        this.backUrl = backUrl;
    }

    public String getCaptcha() {
        return captcha;
    }

    public void setCaptcha(String captcha) {
        this.captcha = captcha;
    }

    public Map<String, List<MallMerchantDto>> getPermissionMap() {
        return permissionMap;
    }

    public void setPermissionMap(Map<String, List<MallMerchantDto>> permissionMap) {
        this.permissionMap = permissionMap;
    }

    public UserMall getUserMall() {
        return userMall;
    }

    public void setUserMall(UserMall userMall) {
        this.userMall = userMall;
    }

    public UserMerchant getUserMerchant() {
        return userMerchant;
    }

    public void setUserMerchant(UserMerchant userMerchant) {
        this.userMerchant = userMerchant;
    }

    public String getLoginDomain() {
        return loginDomain;
    }

    public void setLoginDomain(String loginDomain) {
        this.loginDomain = loginDomain;
    }

    public List<Map<String, Object>> getPermissionList() {
        return permissionList;
    }

    public void setPermissionList(List<Map<String, Object>> permissionList) {
        this.permissionList = permissionList;
    }

    public List<String> getSetCookieCustomerDomainList() {
        return setCookieCustomerDomainList;
    }

    public void setSetCookieCustomerDomainList(List<String> setCookieCustomerDomainList) {
        this.setCookieCustomerDomainList = setCookieCustomerDomainList;
    }

    public String getReferer() {
        return referer;
    }

    public void setReferer(String referer) {
        this.referer = referer;
    }

    public String getCustomLogin() {
        return customLogin;
    }

    public void setCustomLogin(String customLogin) {
        this.customLogin = customLogin;
    }

    public String getCustomLoginMallUrl() {
        return customLoginMallUrl;
    }

    public void setCustomLoginMallUrl(String customLoginMallUrl) {
        this.customLoginMallUrl = customLoginMallUrl;
    }

    public String getCustomLoginMerchantUrl() {
        return customLoginMerchantUrl;
    }

    public void setCustomLoginMerchantUrl(String customLoginMerchantUrl) {
        this.customLoginMerchantUrl = customLoginMerchantUrl;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getSystemType() {
        return systemType;
    }

    public void setSystemType(String systemType) {
        this.systemType = systemType;
    }

    public UserAdmin getUserAdmin() {
        return userAdmin;
    }

    public void setUserAdmin(UserAdmin userAdmin) {
        this.userAdmin = userAdmin;
    }

    public List<String> getErrorMessage() {
        return errorMessage;
    }

    public void setErrorMessage(List<String> errorMessage) {
        this.errorMessage = errorMessage;
    }

    public List<MenuTreeDTO> getResourceList() {
        return resourceList;
    }

    public void setResourceList(List<MenuTreeDTO> resourceList) {
        this.resourceList = resourceList;
    }

    public String getIsSuper() {
        return isSuper;
    }

    public void setIsSuper(String isSuper) {
        this.isSuper = isSuper;
    }

    public String getHostname() {
        return hostname;
    }

    public void setHostname(String hostname) {
        this.hostname = hostname;
    }

    @Override
    public String toString() {
        return "UserInfoDto{" +
                "username='" + username + '\'' +
                ", password='" + password + '\'' +
                ", mall=" + mall +
                ", merchant=" + merchant +
                ", mallMap=" + mallMap +
                ", merchantMap=" + merchantMap +
                ", permissionMap=" + permissionMap +
                ", backUrl='" + backUrl + '\'' +
                ", captcha='" + captcha + '\'' +
                ", permissionList=" + permissionList +
                ", userToken='" + userToken + '\'' +
                ", loginDomain='" + loginDomain + '\'' +
                ", setCookieCustomerDomainList=" + setCookieCustomerDomainList +
                ", referer='" + referer + '\'' +
                ", customLogin='" + customLogin + '\'' +
                ", customLoginMallUrl='" + customLoginMallUrl + '\'' +
                ", customLoginMerchantUrl='" + customLoginMerchantUrl + '\'' +
                ", mobile='" + mobile + '\'' +
                ", email='" + email + '\'' +
                ", userAdmin=" + userAdmin +
                ", systemType='" + systemType + '\'' +
                ", errorMessage=" + errorMessage +
                ", isSuper='" + isSuper + '\'' +
                ", resourceList=" + resourceList +
                ", hostname='" + hostname + '\'' +
                '}';
    }
}
